Skip to content

Return explicit status for direct updates and skip descendants on conflict#14

Merged
Phlogistique merged 1 commit into
mainfrom
codex/add-explicit-status-in-update_direct_target
Dec 25, 2025
Merged

Return explicit status for direct updates and skip descendants on conflict#14
Phlogistique merged 1 commit into
mainfrom
codex/add-explicit-status-in-update_direct_target

Conversation

@Phlogistique

Copy link
Copy Markdown
Collaborator

Motivation

  • Ensure callers can detect when update_direct_target encountered merge conflicts versus succeeded.
  • Prevent attempting to update descendant branches when a direct target failed due to conflicts.
  • Provide a clear log message to indicate descendants are skipped until conflicts are resolved.

Description

  • Updated update-pr-stack.sh to make update_direct_target return 0 on success and 1 when merge conflicts are detected.
  • Added an explicit return 0 after the successful custom-merge path and return 1 in the conflict handling path.
  • Changed main to call update_branch_recursive only if update_direct_target returns success, otherwise it echoes a warning like ⚠️ Skipping descendants of $BRANCH until conflicts are resolved.
  • Modified output and labeling behavior remains the same, and the change is contained to update-pr-stack.sh.

Testing

  • No automated tests were run for this change.
  • The repository changes were committed locally and the updated script file is staged and committed.
  • Basic invocation paths were not executed in CI as part of this patch.
  • Manual verification is recommended when running the script in a real repository to validate conflict and success flows.

Codex Task

@Phlogistique
Phlogistique merged commit 1fd05bf into main Dec 25, 2025
@github-actions
github-actions Bot deleted the codex/add-explicit-status-in-update_direct_target branch December 25, 2025 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant